package com.study.gank.mvp.model

import com.study.gank.api.GankApi
import com.study.gank.bean.BaseResult
import com.study.gank.bean.GankGoods
import com.study.gank.mvp.contract.RandomContract
import io.reactivex.Observable
import io.reactivex.Scheduler
import io.reactivex.schedulers.Schedulers
import javax.inject.Inject

class RandomModel @Inject constructor(private val gankApi: GankApi) : RandomContract.Model {
    override fun getRandom(type: String): Observable<BaseResult<List<GankGoods>>> {
        return gankApi.getRandom(type)
    }
}